#ifndef QBUDDYFACE_H
#define QBUDDYFACE_H

#include <QWidget>
#include <QPushButton>
#include <QLabel>
#include "txim.h"

class qbuddyface : public QWidget
{
	Q_OBJECT

public:
	qbuddyface(QWidget *parent, UINT64 uin, bool bGroup = false);
	~qbuddyface();

public:
	void setText(const QString & text);
	void setHead(WORD wID);
	void setShark(bool bShark);
	UINT64 getUin();

public Q_SLOTS:
	void OnDbClick();

protected:
	virtual void resizeEvent(QResizeEvent * event);
	virtual void timerEvent(QTimerEvent *event);

private:
	QPushButton *pBtn;
	QLabel *pLable;
	UINT64 uin;
	bool bGroup;
	int nTimerID;
	int direction;
	static QIcon* headImage[67][4];
};

#endif // QBUDDYFACE_H
